﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Web.Caching;

namespace Vowei.Service
{
    public interface IServiceHttpContext
    {
        string ApplicationPath { get; }

        IServiceHttpCache Cache { get; }
    }

    public interface IServiceHttpCache
    {
        int Count { get; }

        long EffectivePercentagePhysicalMemoryLimit { get; }

        long EffectivePrivateBytesLimit { get; }

        object this[string key] { get; set; }

        object Add(string key, object value, CacheDependency dependencies, DateTime absoluteExpiration, TimeSpan slidingExpiration, CacheItemPriority priority, CacheItemRemovedCallback onRemoveCallback);

        object Get(string key);

        void Insert(string key, object value);
        
        void Insert(string key, object value, CacheDependency dependencies, DateTime absoluteExpiration, TimeSpan slidingExpiration, CacheItemPriority priority, CacheItemRemovedCallback onRemoveCallback);
       
        object Remove(string key);
    }
}
